<template>
  <el-carousel height="600px">
    <el-carousel-item v-for="(banner, index) in banners" :key="index">
      <img :src="banner.img" alt="">
    </el-carousel-item>
  </el-carousel>
</template>
<script>
export default {
  name: "BannerCarousel",
  data() {
    return {
      banners: [
        { img: '/img/banner1.jpg' },
        { img: '/img/banner3.jpg' },
        { img: '/img/banner4.jpeg' },
      ]
    }
  },
}
</script>
<style>
img {
  width: 100%;
  height: 100%;
  object-fit:cover;
}
</style>
